home *** CD-ROM | disk | FTP | other *** search
- //simple shader to clip any pixels with a Z coordinate below the water plane
- //doesn't do any shading, just texture sampling
- //must be used with clipZ.vsh
- //Luke Lenhart
- //(C)2004-2005 Digipen Institute of Technology
-
- //base texture
- sampler2D sampTex;
-
- //shader input
- struct PS_INPUT
- {
- float4 Pos : TEXCOORD1;
- float2 Tex0 : TEXCOORD0;
- };
-
- //shader
- float4 PShader(PS_INPUT In) : COLOR
- {
- clip(In.Pos.z);
-
- return tex2D(sampTex,In.Tex0);
- };
-